package com.yaorange.system.api;


import com.yaorange.common.core.constant.SecurityConstants;
import com.yaorange.common.core.constant.ServiceNameConstants;
import com.yaorange.common.core.domain.R;
import com.yaorange.system.api.factory.RemoteTeachingFallbackFactory;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.PutMapping;
import org.springframework.web.bind.annotation.RequestHeader;

/**
 * 用户服务
 *
 * @author ruoyi
 */
@FeignClient(contextId = "remoteTeachingService", value = ServiceNameConstants.TEACHING_SERVICE, fallbackFactory = RemoteTeachingFallbackFactory.class)
public interface RemoteTeachingService
{
    @PostMapping("/daily_tasks")
    public abstract R<Void> createDailyTask(@RequestHeader(SecurityConstants.FROM_SOURCE) String source);

    @PutMapping("/daily_tasks/check")
    R<Void> checkDailyTask(@RequestHeader(SecurityConstants.FROM_SOURCE) String source);
}
